<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    
    <title>conci</title>
    <meta name="description" content="求知若饥 虚心若愚">
<meta property="og:type" content="website">
<meta property="og:title" content="cc">
<meta property="og:url" content="http://www.ccblog.win/index.html">
<meta property="og:site_name" content="cc">
<meta property="og:description" content="求知若饥 虚心若愚">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="cc">
<meta name="twitter:description" content="求知若饥 虚心若愚">
    
        <link rel="alternate" href="true" title="cc" type="application/atom+xml">
    
    
        <link rel="icon" href="/favicon.ico">
    
    <link rel="stylesheet" href="/css/concise.css">
    <script src="/js/concise.js"></script>
    <script>
        (function(){
            var useragent=navigator.userAgent;
            console.log(navigator,useragent);
            var isM;
            if(useragent.indexOf('iPhone')!=-1){
                isM=true;
            }else if(useragent.indexOf('Android ')!=-1){
                isM=true;
            }else if(useragent.indexOf('iPad')!=-1){
                isM=true;
            }else{
                isM=false;
            }
            if(isM){
                document.documentElement.style.fontSize=document.documentElement.clientWidth/375*100+'px';
                window.onresize=function(){
                    document.documentElement.style.fontSize=document.documentElement.clientWidth/375*100+'px';
                };
            }
        })();
    </script>
    
        <script type="text/javascript" id="hexo.configuration">
            var CONFIG = {
                root: '/',
                algolia: {
                    applicationID: '148WKKLBJ2',
                    apiKey: '1b27867f0ba7ad358543a84d6d30bcb3',
                    indexName: 'test',
                    hits: {
                        per_page: ''
                    },
                    labels: {
                        input_placeholder: '请输入要搜索的字段...',
                        hits_empty: '没有查找到和 「${query}」相关的内容',
                        hits_stats: '总共${hits} 条相关条目，使用了 ${time} 毫秒'
                    }
                }
            };
        </script>
    
    <script src="http://opu30aljn.bkt.clouddn.com/jquery.js"></script>
    
        <script src="http://opu30aljn.bkt.clouddn.com/instantsearch.js"></script>
        <script src="/js/thirdparty/algolia.js"></script>
    
    <script src="/js/script.js"></script>
</head>
<body>
<input type="checkbox" id="left-information">
<div id="wrapper">
    <div id="bgg"></div>
    <header id="header">
    <nav id="nav" class="clearfix">
        <label for="left-information"></label>
        <ul class='nav-left'>
            <li><a href="/">ccblog</a></li>
        </ul>
        <input type="checkbox" id="header-right-nav">
        <ul class="clearfix nav-right">
            
            <li><a href="/">Home</a></li>
            
            <li><a href="/about">About</a></li>
            
            <li><a href="/contact">Contact</a></li>
            
            <li><a href="/archives">Archives</a></li>
            
            <li><a href="/tags">tags</a></li>
            
        </ul>
        <label for="header-right-nav"><i></i></label>
    </nav>
</header>
    <article id="logo">
    <div id="logo-content">
        <header>
            <a href="">cc&#39;s .blog<b>conci</b></a>
        </header>
        <p>
            conci theme 1.0.0<br>
            Simple and practical hexo personal blog theme.<br>
            The freedom to choose
        </p>
    </div>
</article>
    <div id="main" class="clearfix">
        <section id="main-left" class="left">
            
    
        
            <article class="post">
    <h3><a href="/2017/07/17/在npm发布一个自己的包/">在npm发布一个自己的包</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/07/17/在npm发布一个自己的包/" class="leancloud_visitors" data-flag-title="在npm发布一个自己的包">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/npm/">npm</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,07,17</span>
    </p>
    <div class="post-image">
        <a href="/2017/07/17/在npm发布一个自己的包/"><img src="http://ooa3lxrpg.bkt.clouddn.com/11.jpg"></a>
    </div>
    
        
        <div class="page-content">今天通过一个简单的列子来演示怎么在npm发布自己的包。你需要先下载安装node.js发布包新建个文件夹，这里命名为test110，，然后再在test110下新建一个lib文件夹。创建package.json,在test110文件夹下，右键选择git bash here输入命令1npm init然后name输入test110，然后一路回车，最后ctrl + c结束,创建readme.md文件，在te...</div>
    
    <div class="post-readmore">
        <a href="/2017/07/17/在npm发布一个自己的包/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/27/不用下载第三方软件，快速搭建一个本地服务/">不用下载第三方软件，快速搭建一个本地服务</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/27/不用下载第三方软件，快速搭建一个本地服务/" class="leancloud_visitors" data-flag-title="不用下载第三方软件，快速搭建一个本地服务">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/web前端/">web前端</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,27</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/27/不用下载第三方软件，快速搭建一个本地服务/"><img src="http://ooa3lxrpg.bkt.clouddn.com/11.jpg"></a>
    </div>
    
        
        <div class="page-content">本篇要讲一下不用下载第三方软件就可以快速搭建一个web服务的方法。1.开始 》 控制面板 》 程序和功能 》 打开或关闭windows功能选中所有Internet信息服务（==注意==：在外面选中最上层的Internet信息服务文件夹有可能里面的子文件夹还是没选中，所以你得一个一个打开全选中。）如下图所示：确定，需要等待一小会。开始 》 控制面板 》 管理工具，双击打开Internet 信息服务(...</div>
    
    <div class="post-readmore">
        <a href="/2017/06/27/不用下载第三方软件，快速搭建一个本地服务/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/26/HTML5探秘：用requestAnimationFrame优化Web动画(1)/">HTML5探秘：用requestAnimationFrame优化Web动画</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/26/HTML5探秘：用requestAnimationFrame优化Web动画(1)/" class="leancloud_visitors" data-flag-title="HTML5探秘：用requestAnimationFrame优化Web动画">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/web动画/">web动画</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,26</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/26/HTML5探秘：用requestAnimationFrame优化Web动画(1)/"><img src="http://ooa3lxrpg.bkt.clouddn.com/12.jpg"></a>
    </div>
    
        
        <div class="page-content">如果你从来没有开发过浏览器里的动画，那你不需要读这篇文章 🙂requestAnimationFrame是什么？在浏览器动画程序中，我们通常使用一个定时器来循环每隔几毫秒移动目标物体一次，来让它动起来。如今有一个好消息，浏览器开发商们决定：“嗨，为什么我们不在浏览器里提供这样一个API呢，这样一来我们可以为用户优化他们的动画。”所以，这个requestAnimationFrame()函数就是针对动...</div>
    
    <div class="post-readmore">
        <a href="/2017/06/26/HTML5探秘：用requestAnimationFrame优化Web动画(1)/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/09/一种统一图标大小的方法/">一种统一图标大小的方法</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/09/一种统一图标大小的方法/" class="leancloud_visitors" data-flag-title="一种统一图标大小的方法">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/字体图标/">字体图标</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,09</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/09/一种统一图标大小的方法/"><img src="http://ooa3lxrpg.bkt.clouddn.com/11.jpg"></a>
    </div>
    
        
        <div class="page-content">好东西和好的小技巧不能藏着，掖着，一定要告诉大家，与大家一起分享。今天分享一个设计统一图标大小的方法来自简书上的妖叶秋的分享。当我们想要在整理设计稿中出现的图标，整理除了汇总之外，还需要重新调整一下图标的大小，使他们看起来“差不多大”。想要弄成一致性和统一性，非常的麻烦和耗时。于是作者最后在谷歌的Material Design找到了一种规定的方式，特此来跟大家分享一下。统一图标大小的模型上图就是我...</div>
    
    <div class="post-readmore">
        <a href="/2017/06/09/一种统一图标大小的方法/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/06/bootstrap解析-排版/">bootstrap解析-排版</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/06/bootstrap解析-排版/" class="leancloud_visitors" data-flag-title="bootstrap解析-排版">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/bootstrap解析/">bootstrap解析</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,06</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/06/bootstrap解析-排版/"><img src="http://ooa3lxrpg.bkt.clouddn.com/11.jpg"></a>
    </div>
    
        
        <div class="page-content">标题12345678&amp;lt;h1&amp;gt;36px   .h1&amp;lt;h2&amp;gt;30px   .h2&amp;lt;h3&amp;gt;24px   .h3&amp;lt;h4&amp;gt;18px   .h4&amp;lt;h5&amp;gt;14px   .h5&amp;lt;h6&amp;gt;12px   .h6&amp;lt;small&amp;gt; 当前字体的65%   .small前面4个各差6px,h4-h5差4px,h5-h6差2px.h*是为了给inl...</div>
    
    <div class="post-readmore">
        <a href="/2017/06/06/bootstrap解析-排版/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/06/bootstrap解析-栅格系统/">bootstrap解析-栅格系统</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/06/bootstrap解析-栅格系统/" class="leancloud_visitors" data-flag-title="bootstrap解析-栅格系统">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/bootstrap解析/">bootstrap解析</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,06</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/06/bootstrap解析-栅格系统/"><img src="http://ooa3lxrpg.bkt.clouddn.com/11.jpg"></a>
    </div>
    
        
        <div class="page-content">bootstrap解析-栅格系统.container(布局容器)屏幕宽1200px以上（col-lg）默认width为1170pxpadding,lefet和right各为15px,所以内容width为1140px;屏幕宽992px以上(col-md)默认width为970pxpadding,lefet和right各为15px,所以内容width为940px;屏幕宽768px以上(col-sm)默...</div>
    
    <div class="post-readmore">
        <a href="/2017/06/06/bootstrap解析-栅格系统/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/06/01/hexo主题配置conci/">hexo主题配置conci</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/06/01/hexo主题配置conci/" class="leancloud_visitors" data-flag-title="hexo主题配置conci">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/hexo主题/">hexo主题</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,06,01</span>
    </p>
    <div class="post-image">
        <a href="/2017/06/01/hexo主题配置conci/"><img src="http://ooa3lxrpg.bkt.clouddn.com/12.jpg"></a>
    </div>
    
        
        <div class="page-content">继续叨叨叨之前介绍了hexo的安装和部署（还没部署的小伙伴点这里)，这篇咱们接着介绍怎么应用主题。conci主题(github)这里主要是配置的conci主题下载concihexo的主题都存放在themes文件夹下，在themes文件夹下右键Git bash Here，输入：1$ git clone https://github.com/cspp01/concise.git然后在主_config....</div>
    
    <div class="post-readmore">
        <a href="/2017/06/01/hexo主题配置conci/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/05/31/jquery显示隐藏常用方式性能测试报告/">jquery显示隐藏常用方式性能测试报告</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/05/31/jquery显示隐藏常用方式性能测试报告/" class="leancloud_visitors" data-flag-title="jquery显示隐藏常用方式性能测试报告">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/jquery/">jquery</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,05,31</span>
    </p>
    <div class="post-image">
        <a href="/2017/05/31/jquery显示隐藏常用方式性能测试报告/"><img src="http://ooa3lxrpg.bkt.clouddn.com/8.jpg"></a>
    </div>
    
        
        <div class="page-content">其实我一直就听别人说如果要显示隐藏尽量不要用hide()和show(),其实一直也没实际测试过，因为自己想当然的也以为，毕竟hide()和show()jquery底层要经过不少判断。今天不知怎么得对他们的性能一直很在意，于是就简单做了如下测试下面测试了对10000个相同div节点的显示隐藏，测试方法使用了console.time()和console.timeEnd,测试浏览器为谷歌（其它的还没测试...</div>
    
    <div class="post-readmore">
        <a href="/2017/05/31/jquery显示隐藏常用方式性能测试报告/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/05/05/html,css填坑路/">css,html填坑路</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/05/05/html,css填坑路/" class="leancloud_visitors" data-flag-title="css,html填坑路">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/htmlcss/">htmlcss</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,05,05</span>
    </p>
    <div class="post-image">
        <a href="/2017/05/05/html,css填坑路/"><img src="http://ooa3lxrpg.bkt.clouddn.com/9.jpg"></a>
    </div>
    
        
        <div class="page-content">前端填坑路1.外边距合并例子：1.子元素设置margin-top;父元素不设置margin-top;,但父元素会出现上边距，子元素相对父元素却不会出现。 2.同级元素上面那个设置margin-bottom：下面那个设置margin-top:可是中间的间距却不是两个边距的和。原因：这个是css默认行为，因为元素没有找到另一个那个元素的边界，只在垂直方向的外边距合并，合并为边距中最大的那个，水平方向的...</div>
    
    <div class="post-readmore">
        <a href="/2017/05/05/html,css填坑路/">Read More</a>
    </div>
</article>
        
            <article class="post">
    <h3><a href="/2017/04/05/利用css边框做出三角形,梯形/">利用css边框做出三角形,梯形</a></h3>
    <p>
        
            <span class="visitors">visitors
                <span id="/2017/04/05/利用css边框做出三角形,梯形/" class="leancloud_visitors" data-flag-title="利用css边框做出三角形,梯形">
                    <span class="leancloud-visitors-count">0</span>
                </span>
            </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        
        <span class="tag">
                    <a class="article-category-link" href="/categories/css/">css</a>
                </span>&nbsp;&nbsp;•&nbsp;&nbsp;
        <span class="date">2017,04,05</span>
    </p>
    <div class="post-image">
        <a href="/2017/04/05/利用css边框做出三角形,梯形/"><img src="http://ooa3lxrpg.bkt.clouddn.com/6.jpg"></a>
    </div>
    
        
        <div class="page-content">在网页中常能看到三角形，可是我们都知道网页中只有矩形边框，那这些三角形是怎么做出来的呢。其实做出这些三角形是利用了边框。如果了解边宽的话应该都知道边框的结构是下面这样的。如果我将width,height以及padding都设为0,也就是上图区域1为none,那么渐变为下图这样。是不是已经看到4个三角形了，对的，这就是我们需要的，接着就看你需要哪个方向的三角形，然后设置对边为none,侧边两边为透明...</div>
    
    <div class="post-readmore">
        <a href="/2017/04/05/利用css边框做出三角形,梯形/">Read More</a>
    </div>
</article>
        
    


<nav id="index-pading">
    pages:&nbsp;&nbsp;
    <span class="page-number current">1</span><a class="page-number" href="/page/2/">2</a><a class="extend next" rel="next" href="/page/2/"><span class="index-next">&nbsp;»</span></a>
</nav>

        </section>
        <section id="main-right" class="right">
            <div class="my">
    <div class="my-information">
        <div class="my-img">
            <img src="http://ooa3lxrpg.bkt.clouddn.com/b.jpg?imageView2/1/w/120/h/120/q/75" rel="图片">
            <a href="https://github.com/cspp01"></a>
        </div>
        <span>cc</span>
        <p>求知若饥 虚心若愚</p>
    </div>
    <p class="my-social">
        
            <a href="https://github.com/cspp01" class="my-social-me5">github</a>
        
            <a href="/" class="my-social-me2">twitter</a>
        
            <a href="http://weibo.com/5262373626/profile?topnav=1&wvr=6&is_all=1" class="my-social-me2">weibo</a>
        
            <a href="http://douban.com/people/160374034/" class="my-social-me2">豆瓣</a>
        
            <a href="http://www.zhihu.com/people/cc-chen-4-85" class="my-social-me1">知乎</a>
        
    </p>
    <div class="my-post">
        <a href="/archives">
            <strong>19</strong><br>
            <span>posts</span>
        </a>
        <a href="/categories">
            <strong>11</strong><br>
            <span>categories</span>
        </a>
        <a href="/tags">
            <strong>21</strong><br>
            <span>tags</span>
        </a>
    </div>
    <div class="search-rss">
        <div class="my-search">
            <a href="javascript:void(0)" id ='my-search-a' class="popup-trigger">search</a>
        </div>
        
            <div class="my-rss">
                <a href="/atom.xml">rss</a>
            </div>
        
    </div>
    <div class="my-links">
        <ul class="clearfix">
            
            <li>
                <a href="/">
                    <img src="http://ooa3lxrpg.bkt.clouddn.com/timg.jpg">
                    <p>ccblog</p>
                </a>
            </li>
            
            <li>
                <a href="/">
                    <img src="http://ooa3lxrpg.bkt.clouddn.com/timg%20%282%29.jpg">
                    <p>boc</p>
                </a>
            </li>
            
            <li>
                <a href="/">
                    <img src="http://ooa3lxrpg.bkt.clouddn.com/timg%20%283%29.jpg">
                    <p>haha</p>
                </a>
            </li>
            
            <li>
                <a href="/">
                    <img src="http://ooa3lxrpg.bkt.clouddn.com/timg%20%283%29.jpg">
                    <p>pp</p>
                </a>
            </li>
            
            <li>
                <a href="/">
                    <img src="http://ooa3lxrpg.bkt.clouddn.com/timg%20%281%29.jpg">
                    <p>oop</p>
                </a>
            </li>
            
        </ul>
    </div>
    <div class="hot-page">
        
    </div>
</div>
            
        </section>
    </div>
    <footer id="footer">
    <p>© 2017  cc | <iframe src="https://ghbtns.com/github-btn.html?user=cspp01&repo=cspp01.github.io&type=star&count=true" >
        </iframe><br/>
        concise theme, this world is mine.  | cc'blog | Fork me on Github
        
            | <script type="text/javascript">var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_stat_icon_1261969111'%3E%3C/span%3E%3Cscript src='" + cnzz_protocol + "s19.cnzz.com/z_stat.php%3Fid%3D1261969111%26show%3Dpic' type='text/javascript'%3E%3C/script%3E"));</script>
        
    </p>
</footer>
</div>
<label for="left-information"></label>


    <div class="site-search">
        <div class="algolia-popup popup">
            <div class="algolia-search">
                <div class="algolia-search-input-icon">
                    <i class="fa fa-search"></i>
                </div>
                <div class="algolia-search-input" id="algolia-search-input"></div>
            </div>

            <div class="algolia-results">
                <div id="algolia-stats"></div>
                <div id="algolia-hits"></div>
                <div id="algolia-pagination" class="algolia-pagination"></div>
            </div>

            <span class="popup-btn-close">
          <i class="fa fa-times-circle"></i>
        </span>
        </div>
    </div>


<script src="https://cdn1.lncld.net/static/js/av-core-mini-0.6.1.js"></script>
<script>AV.initialize("rRxCAb8Kk2bhhTQJInFKaY4v-gzGzoHsz", "eEp5YWpvXhpv3Jvheh4bHCfG");</script>
<script>
    function showTime(test) {
        var query = new AV.Query(test);
        var entries = [];
        var $visitors = $(".leancloud_visitors");

        $visitors.each(function () {
            entries.push( $(this).attr("id").trim() );
        });

        query.containedIn('url', entries);
        query.find()
            .done(function (results) {
                var COUNT_CONTAINER_REF = '.leancloud-visitors-count';

                if (results.length === 0) {
                    $visitors.find(COUNT_CONTAINER_REF).text(0);
                    return;
                }

                for (var i = 0; i < results.length; i++) {
                    var item = results[i];
                    var url = item.get('url');
                    var time = item.get('time');
                    var element = document.getElementById(url);

                    $(element).find(COUNT_CONTAINER_REF).text(time);
                }
            })
            .fail(function (object, error) {
                console.log("Error: " + error.code + " " + error.message);
            });
    }

    function addCount(test) {
        var $visitors = $(".leancloud_visitors");
        var url = $visitors.attr('id').trim();
        var title = $visitors.attr('data-flag-title').trim();
        var query = new AV.Query(test);

        query.equalTo("url", url);
        query.find({
            success: function(results) {
                if (results.length > 0) {
                    var counter = results[0];
                    counter.fetchWhenSave(true);
                    counter.increment("time");
                    counter.save(null, {
                        success: function(counter) {
                            var $element = $(document.getElementById(url));
                            $element.find('.leancloud-visitors-count').text(counter.get('time'));
                        },
                        error: function(counter, error) {
                            console.log('Failed to save Visitor num, with error message: ' + error.message);
                        }
                    });
                } else {
                    var newcounter = new test();
                    /* Set ACL */
                    var acl = new AV.ACL();
                    acl.setPublicReadAccess(true);
                    acl.setPublicWriteAccess(true);
                    newcounter.setACL(acl);
                    /* End Set ACL */
                    newcounter.set("title", title);
                    newcounter.set("url", url);
                    newcounter.set("time", 1);
                    newcounter.save(null, {
                        success: function(newcounter) {
                            var $element = $(document.getElementById(url));
                            $element.find('.leancloud-visitors-count').text(newcounter.get('time'));
                        },
                        error: function(newcounter, error) {
                            console.log('Failed to create');
                        }
                    });
                }
            },
            error: function(error) {
                console.log('Error:' + error.code + " " + error.message);
            }
        });
    }

    $(function() {
        var test = AV.Object.extend("Counter");
        if ($('.leancloud_visitors').length == 1) {
            addCount(test);
        } else if ($('.leancloud_visitors').length > 1) {
            showTime(test);
        }
    });
</script>



<script>
    (function(){
        var bp = document.createElement('script');
        var curProtocol = window.location.protocol.split(':')[0];
        if (curProtocol === 'https') {
            bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
        }
        else {
            bp.src = 'http://push.zhanzhang.baidu.com/push.js';
        }
        var s = document.getElementsByTagName("script")[0];
        s.parentNode.insertBefore(bp, s);
    })();
</script>

</body>

</html>